Integrand size = 16, antiderivative size = 329 \[ \int \frac {x}{\left (a+b \sin ^2(c+d x)\right )^2} \, dx=-\frac {i (2 a+b) x \log \left (1-\frac {b e^{2 i (c+d x)}}{2 a+b-2 \sqrt {a} \sqrt {a+b}}\right )}{4 a^{3/2} (a+b)^{3/2} d}+\frac {i (2 a+b) x \log \left (1-\frac {b e^{2 i (c+d x)}}{2 a+b+2 \sqrt {a} \sqrt {a+b}}\right )}{4 a^{3/2} (a+b)^{3/2} d}-\frac {\log (2 a+b-b \cos (2 c+2 d x))}{4 a (a+b) d^2}-\frac {(2 a+b) \operatorname {PolyLog}\left (2,\frac {b e^{2 i (c+d x)}}{2 a+b-2 \sqrt {a} \sqrt {a+b}}\right )}{8 a^{3/2} (a+b)^{3/2} d^2}+\frac {(2 a+b) \operatorname {PolyLog}\left (2,\frac {b e^{2 i (c+d x)}}{2 a+b+2 \sqrt {a} \sqrt {a+b}}\right )}{8 a^{3/2} (a+b)^{3/2} d^2}+\frac {b x \sin (2 c+2 d x)}{2 a (a+b) d (2 a+b-b \cos (2 c+2 d x))} \]
-1/4*ln(2*a+b-b*cos(2*d*x+2*c))/a/(a+b)/d^2-1/4*I*(2*a+b)*x*ln(1-b*exp(2*I *(d*x+c))/(2*a+b-2*a^(1/2)*(a+b)^(1/2)))/a^(3/2)/(a+b)^(3/2)/d+1/4*I*(2*a+ b)*x*ln(1-b*exp(2*I*(d*x+c))/(2*a+b+2*a^(1/2)*(a+b)^(1/2)))/a^(3/2)/(a+b)^ (3/2)/d-1/8*(2*a+b)*polylog(2,b*exp(2*I*(d*x+c))/(2*a+b-2*a^(1/2)*(a+b)^(1 /2)))/a^(3/2)/(a+b)^(3/2)/d^2+1/8*(2*a+b)*polylog(2,b*exp(2*I*(d*x+c))/(2* a+b+2*a^(1/2)*(a+b)^(1/2)))/a^(3/2)/(a+b)^(3/2)/d^2+1/2*b*x*sin(2*d*x+2*c) /a/(a+b)/d/(2*a+b-b*cos(2*d*x+2*c))
Both result and optimal contain complex but leaf count is larger than twice the leaf count of optimal. \(855\) vs. \(2(329)=658\).
Time = 15.25 (sec) , antiderivative size = 855, normalized size of antiderivative = 2.60 \[ \int \frac {x}{\left (a+b \sin ^2(c+d x)\right )^2} \, dx=\frac {b c \sin (2 (c+d x))-b (c+d x) \sin (2 (c+d x))}{2 a (a+b) d^2 (-2 a-b+b \cos (2 (c+d x)))}+\frac {\cos ^2(c+d x) \left (-\frac {4 (2 a+b) c \arctan \left (\frac {\sqrt {a+b} \tan (c+d x)}{\sqrt {a}}\right )}{\sqrt {a} \sqrt {a+b}}+2 \log \left (\sec ^2(c+d x)\right )-2 \log \left (a+(a+b) \tan ^2(c+d x)\right )-\frac {i (2 a+b) \left (\log (1-i \tan (c+d x)) \log \left (\frac {\sqrt {a}-\sqrt {-a-b} \tan (c+d x)}{\sqrt {a}+i \sqrt {-a-b}}\right )+\operatorname {PolyLog}\left (2,\frac {\sqrt {-a-b} (1-i \tan (c+d x))}{-i \sqrt {a}+\sqrt {-a-b}}\right )\right )}{\sqrt {a} \sqrt {-a-b}}+\frac {i (2 a+b) \left (\log (1-i \tan (c+d x)) \log \left (\frac {\sqrt {a}+\sqrt {-a-b} \tan (c+d x)}{\sqrt {a}-i \sqrt {-a-b}}\right )+\operatorname {PolyLog}\left (2,\frac {\sqrt {-a-b} (1-i \tan (c+d x))}{i \sqrt {a}+\sqrt {-a-b}}\right )\right )}{\sqrt {a} \sqrt {-a-b}}-\frac {i (2 a+b) \left (\log (1+i \tan (c+d x)) \log \left (\frac {\sqrt {a}+\sqrt {-a-b} \tan (c+d x)}{\sqrt {a}+i \sqrt {-a-b}}\right )+\operatorname {PolyLog}\left (2,\frac {\sqrt {-a-b} (1+i \tan (c+d x))}{-i \sqrt {a}+\sqrt {-a-b}}\right )\right )}{\sqrt {a} \sqrt {-a-b}}+\frac {i (2 a+b) \left (\log (1+i \tan (c+d x)) \log \left (\frac {\sqrt {a}-\sqrt {-a-b} \tan (c+d x)}{\sqrt {a}-i \sqrt {-a-b}}\right )+\operatorname {PolyLog}\left (2,\frac {\sqrt {-a-b} (1+i \tan (c+d x))}{i \sqrt {a}+\sqrt {-a-b}}\right )\right )}{\sqrt {a} \sqrt {-a-b}}\right ) (2 (2 a+b) d x-b \sin (2 (c+d x))) \left (\sqrt {a}-\sqrt {-a-b} \tan (c+d x)\right ) \left (\sqrt {a}+\sqrt {-a-b} \tan (c+d x)\right )}{4 a (a+b) d^2 (-2 a-b+b \cos (2 (c+d x))) ((2 a+b) (2 c-i \log (1-i \tan (c+d x))+i \log (1+i \tan (c+d x)))+b \sin (2 (c+d x)))} \]
(b*c*Sin[2*(c + d*x)] - b*(c + d*x)*Sin[2*(c + d*x)])/(2*a*(a + b)*d^2*(-2 *a - b + b*Cos[2*(c + d*x)])) + (Cos[c + d*x]^2*((-4*(2*a + b)*c*ArcTan[(S qrt[a + b]*Tan[c + d*x])/Sqrt[a]])/(Sqrt[a]*Sqrt[a + b]) + 2*Log[Sec[c + d *x]^2] - 2*Log[a + (a + b)*Tan[c + d*x]^2] - (I*(2*a + b)*(Log[1 - I*Tan[c + d*x]]*Log[(Sqrt[a] - Sqrt[-a - b]*Tan[c + d*x])/(Sqrt[a] + I*Sqrt[-a - b])] + PolyLog[2, (Sqrt[-a - b]*(1 - I*Tan[c + d*x]))/((-I)*Sqrt[a] + Sqrt [-a - b])]))/(Sqrt[a]*Sqrt[-a - b]) + (I*(2*a + b)*(Log[1 - I*Tan[c + d*x] ]*Log[(Sqrt[a] + Sqrt[-a - b]*Tan[c + d*x])/(Sqrt[a] - I*Sqrt[-a - b])] + PolyLog[2, (Sqrt[-a - b]*(1 - I*Tan[c + d*x]))/(I*Sqrt[a] + Sqrt[-a - b])] ))/(Sqrt[a]*Sqrt[-a - b]) - (I*(2*a + b)*(Log[1 + I*Tan[c + d*x]]*Log[(Sqr t[a] + Sqrt[-a - b]*Tan[c + d*x])/(Sqrt[a] + I*Sqrt[-a - b])] + PolyLog[2, (Sqrt[-a - b]*(1 + I*Tan[c + d*x]))/((-I)*Sqrt[a] + Sqrt[-a - b])]))/(Sqr t[a]*Sqrt[-a - b]) + (I*(2*a + b)*(Log[1 + I*Tan[c + d*x]]*Log[(Sqrt[a] - Sqrt[-a - b]*Tan[c + d*x])/(Sqrt[a] - I*Sqrt[-a - b])] + PolyLog[2, (Sqrt[ -a - b]*(1 + I*Tan[c + d*x]))/(I*Sqrt[a] + Sqrt[-a - b])]))/(Sqrt[a]*Sqrt[ -a - b]))*(2*(2*a + b)*d*x - b*Sin[2*(c + d*x)])*(Sqrt[a] - Sqrt[-a - b]*T an[c + d*x])*(Sqrt[a] + Sqrt[-a - b]*Tan[c + d*x]))/(4*a*(a + b)*d^2*(-2*a - b + b*Cos[2*(c + d*x)])*((2*a + b)*(2*c - I*Log[1 - I*Tan[c + d*x]] + I *Log[1 + I*Tan[c + d*x]]) + b*Sin[2*(c + d*x)]))
Time = 1.19 (sec) , antiderivative size = 329, normalized size of antiderivative = 1.00, number of steps used = 15, number of rules used = 14, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.875, Rules used = {5096, 3042, 3805, 25, 3042, 3147, 16, 3802, 25, 2694, 27, 2620, 2715, 2838}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \frac {x}{\left (a+b \sin ^2(c+d x)\right )^2} \, dx\) |
\(\Big \downarrow \) 5096 |
\(\displaystyle 4 \int \frac {x}{(2 a+b-b \cos (2 c+2 d x))^2}dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle 4 \int \frac {x}{\left (2 a+b-b \sin \left (2 c+2 d x+\frac {\pi }{2}\right )\right )^2}dx\) |
\(\Big \downarrow \) 3805 |
\(\displaystyle 4 \left (\frac {(2 a+b) \int \frac {x}{2 a+b-b \cos (2 c+2 d x)}dx}{4 a (a+b)}+\frac {b \int -\frac {\sin (2 c+2 d x)}{2 a+b-b \cos (2 c+2 d x)}dx}{8 a d (a+b)}+\frac {b x \sin (2 c+2 d x)}{8 a d (a+b) (2 a-b \cos (2 c+2 d x)+b)}\right )\) |
\(\Big \downarrow \) 25 |
\(\displaystyle 4 \left (\frac {(2 a+b) \int \frac {x}{2 a+b-b \cos (2 c+2 d x)}dx}{4 a (a+b)}-\frac {b \int \frac {\sin (2 c+2 d x)}{2 a+b-b \cos (2 c+2 d x)}dx}{8 a d (a+b)}+\frac {b x \sin (2 c+2 d x)}{8 a d (a+b) (2 a-b \cos (2 c+2 d x)+b)}\right )\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle 4 \left (\frac {(2 a+b) \int \frac {x}{2 a+b-b \sin \left (2 c+2 d x+\frac {\pi }{2}\right )}dx}{4 a (a+b)}-\frac {b \int \frac {\cos \left (2 c+2 d x-\frac {\pi }{2}\right )}{2 a+b+b \sin \left (2 c+2 d x-\frac {\pi }{2}\right )}dx}{8 a d (a+b)}+\frac {b x \sin (2 c+2 d x)}{8 a d (a+b) (2 a-b \cos (2 c+2 d x)+b)}\right )\) |
\(\Big \downarrow \) 3147 |
\(\displaystyle 4 \left (-\frac {\int \frac {1}{2 a+b-b \cos (2 c+2 d x)}d(-b \cos (2 c+2 d x))}{16 a d^2 (a+b)}+\frac {(2 a+b) \int \frac {x}{2 a+b-b \sin \left (2 c+2 d x+\frac {\pi }{2}\right )}dx}{4 a (a+b)}+\frac {b x \sin (2 c+2 d x)}{8 a d (a+b) (2 a-b \cos (2 c+2 d x)+b)}\right )\) |
\(\Big \downarrow \) 16 |
\(\displaystyle 4 \left (\frac {(2 a+b) \int \frac {x}{2 a+b-b \sin \left (2 c+2 d x+\frac {\pi }{2}\right )}dx}{4 a (a+b)}-\frac {\log (2 a-b \cos (2 c+2 d x)+b)}{16 a d^2 (a+b)}+\frac {b x \sin (2 c+2 d x)}{8 a d (a+b) (2 a-b \cos (2 c+2 d x)+b)}\right )\) |
\(\Big \downarrow \) 3802 |
\(\displaystyle 4 \left (\frac {(2 a+b) \int -\frac {e^{2 i (c+d x)} x}{e^{4 i (c+d x)} b+b-2 (2 a+b) e^{2 i (c+d x)}}dx}{2 a (a+b)}-\frac {\log (2 a-b \cos (2 c+2 d x)+b)}{16 a d^2 (a+b)}+\frac {b x \sin (2 c+2 d x)}{8 a d (a+b) (2 a-b \cos (2 c+2 d x)+b)}\right )\) |
\(\Big \downarrow \) 25 |
\(\displaystyle 4 \left (-\frac {(2 a+b) \int \frac {e^{2 i (c+d x)} x}{e^{4 i (c+d x)} b+b-2 (2 a+b) e^{2 i (c+d x)}}dx}{2 a (a+b)}-\frac {\log (2 a-b \cos (2 c+2 d x)+b)}{16 a d^2 (a+b)}+\frac {b x \sin (2 c+2 d x)}{8 a d (a+b) (2 a-b \cos (2 c+2 d x)+b)}\right )\) |
\(\Big \downarrow \) 2694 |
\(\displaystyle 4 \left (-\frac {(2 a+b) \left (\frac {b \int -\frac {e^{2 i (c+d x)} x}{2 \left (2 a+2 \sqrt {a+b} \sqrt {a}-b e^{2 i (c+d x)}+b\right )}dx}{2 \sqrt {a} \sqrt {a+b}}-\frac {b \int -\frac {e^{2 i (c+d x)} x}{2 \left (2 a-2 \sqrt {a+b} \sqrt {a}-b e^{2 i (c+d x)}+b\right )}dx}{2 \sqrt {a} \sqrt {a+b}}\right )}{2 a (a+b)}-\frac {\log (2 a-b \cos (2 c+2 d x)+b)}{16 a d^2 (a+b)}+\frac {b x \sin (2 c+2 d x)}{8 a d (a+b) (2 a-b \cos (2 c+2 d x)+b)}\right )\) |
\(\Big \downarrow \) 27 |
\(\displaystyle 4 \left (-\frac {(2 a+b) \left (\frac {b \int \frac {e^{2 i (c+d x)} x}{2 a-2 \sqrt {a+b} \sqrt {a}-b e^{2 i (c+d x)}+b}dx}{4 \sqrt {a} \sqrt {a+b}}-\frac {b \int \frac {e^{2 i (c+d x)} x}{2 a+2 \sqrt {a+b} \sqrt {a}-b e^{2 i (c+d x)}+b}dx}{4 \sqrt {a} \sqrt {a+b}}\right )}{2 a (a+b)}-\frac {\log (2 a-b \cos (2 c+2 d x)+b)}{16 a d^2 (a+b)}+\frac {b x \sin (2 c+2 d x)}{8 a d (a+b) (2 a-b \cos (2 c+2 d x)+b)}\right )\) |
\(\Big \downarrow \) 2620 |
\(\displaystyle 4 \left (-\frac {(2 a+b) \left (\frac {b \left (\frac {i x \log \left (1-\frac {b e^{2 i (c+d x)}}{-2 \sqrt {a} \sqrt {a+b}+2 a+b}\right )}{2 b d}-\frac {i \int \log \left (1-\frac {b e^{2 i (c+d x)}}{2 a-2 \sqrt {a+b} \sqrt {a}+b}\right )dx}{2 b d}\right )}{4 \sqrt {a} \sqrt {a+b}}-\frac {b \left (\frac {i x \log \left (1-\frac {b e^{2 i (c+d x)}}{2 \sqrt {a} \sqrt {a+b}+2 a+b}\right )}{2 b d}-\frac {i \int \log \left (1-\frac {b e^{2 i (c+d x)}}{2 a+2 \sqrt {a+b} \sqrt {a}+b}\right )dx}{2 b d}\right )}{4 \sqrt {a} \sqrt {a+b}}\right )}{2 a (a+b)}-\frac {\log (2 a-b \cos (2 c+2 d x)+b)}{16 a d^2 (a+b)}+\frac {b x \sin (2 c+2 d x)}{8 a d (a+b) (2 a-b \cos (2 c+2 d x)+b)}\right )\) |
\(\Big \downarrow \) 2715 |
\(\displaystyle 4 \left (-\frac {(2 a+b) \left (\frac {b \left (\frac {i x \log \left (1-\frac {b e^{2 i (c+d x)}}{-2 \sqrt {a} \sqrt {a+b}+2 a+b}\right )}{2 b d}-\frac {\int e^{-2 i (c+d x)} \log \left (1-\frac {b e^{2 i (c+d x)}}{2 a-2 \sqrt {a+b} \sqrt {a}+b}\right )de^{2 i (c+d x)}}{4 b d^2}\right )}{4 \sqrt {a} \sqrt {a+b}}-\frac {b \left (\frac {i x \log \left (1-\frac {b e^{2 i (c+d x)}}{2 \sqrt {a} \sqrt {a+b}+2 a+b}\right )}{2 b d}-\frac {\int e^{-2 i (c+d x)} \log \left (1-\frac {b e^{2 i (c+d x)}}{2 a+2 \sqrt {a+b} \sqrt {a}+b}\right )de^{2 i (c+d x)}}{4 b d^2}\right )}{4 \sqrt {a} \sqrt {a+b}}\right )}{2 a (a+b)}-\frac {\log (2 a-b \cos (2 c+2 d x)+b)}{16 a d^2 (a+b)}+\frac {b x \sin (2 c+2 d x)}{8 a d (a+b) (2 a-b \cos (2 c+2 d x)+b)}\right )\) |
\(\Big \downarrow \) 2838 |
\(\displaystyle 4 \left (-\frac {(2 a+b) \left (\frac {b \left (\frac {\operatorname {PolyLog}\left (2,\frac {b e^{2 i (c+d x)}}{2 a-2 \sqrt {a+b} \sqrt {a}+b}\right )}{4 b d^2}+\frac {i x \log \left (1-\frac {b e^{2 i (c+d x)}}{-2 \sqrt {a} \sqrt {a+b}+2 a+b}\right )}{2 b d}\right )}{4 \sqrt {a} \sqrt {a+b}}-\frac {b \left (\frac {\operatorname {PolyLog}\left (2,\frac {b e^{2 i (c+d x)}}{2 a+2 \sqrt {a+b} \sqrt {a}+b}\right )}{4 b d^2}+\frac {i x \log \left (1-\frac {b e^{2 i (c+d x)}}{2 \sqrt {a} \sqrt {a+b}+2 a+b}\right )}{2 b d}\right )}{4 \sqrt {a} \sqrt {a+b}}\right )}{2 a (a+b)}-\frac {\log (2 a-b \cos (2 c+2 d x)+b)}{16 a d^2 (a+b)}+\frac {b x \sin (2 c+2 d x)}{8 a d (a+b) (2 a-b \cos (2 c+2 d x)+b)}\right )\) |
4*(-1/16*Log[2*a + b - b*Cos[2*c + 2*d*x]]/(a*(a + b)*d^2) - ((2*a + b)*(( b*(((I/2)*x*Log[1 - (b*E^((2*I)*(c + d*x)))/(2*a + b - 2*Sqrt[a]*Sqrt[a + b])])/(b*d) + PolyLog[2, (b*E^((2*I)*(c + d*x)))/(2*a + b - 2*Sqrt[a]*Sqrt [a + b])]/(4*b*d^2)))/(4*Sqrt[a]*Sqrt[a + b]) - (b*(((I/2)*x*Log[1 - (b*E^ ((2*I)*(c + d*x)))/(2*a + b + 2*Sqrt[a]*Sqrt[a + b])])/(b*d) + PolyLog[2, (b*E^((2*I)*(c + d*x)))/(2*a + b + 2*Sqrt[a]*Sqrt[a + b])]/(4*b*d^2)))/(4* Sqrt[a]*Sqrt[a + b])))/(2*a*(a + b)) + (b*x*Sin[2*c + 2*d*x])/(8*a*(a + b) *d*(2*a + b - b*Cos[2*c + 2*d*x])))
3.1.4.3.1 Defintions of rubi rules used
Int[(c_.)/((a_.) + (b_.)*(x_)), x_Symbol] :> Simp[c*(Log[RemoveContent[a + b*x, x]]/b), x] /; FreeQ[{a, b, c}, x]
Int[(a_)*(Fx_), x_Symbol] :> Simp[a Int[Fx, x], x] /; FreeQ[a, x] && !Ma tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
Int[(((F_)^((g_.)*((e_.) + (f_.)*(x_))))^(n_.)*((c_.) + (d_.)*(x_))^(m_.))/ ((a_) + (b_.)*((F_)^((g_.)*((e_.) + (f_.)*(x_))))^(n_.)), x_Symbol] :> Simp [((c + d*x)^m/(b*f*g*n*Log[F]))*Log[1 + b*((F^(g*(e + f*x)))^n/a)], x] - Si mp[d*(m/(b*f*g*n*Log[F])) Int[(c + d*x)^(m - 1)*Log[1 + b*((F^(g*(e + f*x )))^n/a)], x], x] /; FreeQ[{F, a, b, c, d, e, f, g, n}, x] && IGtQ[m, 0]
Int[((F_)^(u_)*((f_.) + (g_.)*(x_))^(m_.))/((a_.) + (b_.)*(F_)^(u_) + (c_.) *(F_)^(v_)), x_Symbol] :> With[{q = Rt[b^2 - 4*a*c, 2]}, Simp[2*(c/q) Int [(f + g*x)^m*(F^u/(b - q + 2*c*F^u)), x], x] - Simp[2*(c/q) Int[(f + g*x) ^m*(F^u/(b + q + 2*c*F^u)), x], x]] /; FreeQ[{F, a, b, c, f, g}, x] && EqQ[ v, 2*u] && LinearQ[u, x] && NeQ[b^2 - 4*a*c, 0] && IGtQ[m, 0]
Int[Log[(a_) + (b_.)*((F_)^((e_.)*((c_.) + (d_.)*(x_))))^(n_.)], x_Symbol] :> Simp[1/(d*e*n*Log[F]) Subst[Int[Log[a + b*x]/x, x], x, (F^(e*(c + d*x) ))^n], x] /; FreeQ[{F, a, b, c, d, e, n}, x] && GtQ[a, 0]
Int[Log[(c_.)*((d_) + (e_.)*(x_)^(n_.))]/(x_), x_Symbol] :> Simp[-PolyLog[2 , (-c)*e*x^n]/n, x] /; FreeQ[{c, d, e, n}, x] && EqQ[c*d, 1]
Int[cos[(e_.) + (f_.)*(x_)]^(p_.)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m _.), x_Symbol] :> Simp[1/(b^p*f) Subst[Int[(a + x)^m*(b^2 - x^2)^((p - 1) /2), x], x, b*Sin[e + f*x]], x] /; FreeQ[{a, b, e, f, m}, x] && IntegerQ[(p - 1)/2] && NeQ[a^2 - b^2, 0]
Int[((c_.) + (d_.)*(x_))^(m_.)/((a_) + (b_.)*sin[(e_.) + Pi*(k_.) + (f_.)*( x_)]), x_Symbol] :> Simp[2 Int[(c + d*x)^m*E^(I*Pi*(k - 1/2))*(E^(I*(e + f*x))/(b + 2*a*E^(I*Pi*(k - 1/2))*E^(I*(e + f*x)) - b*E^(2*I*k*Pi)*E^(2*I*( e + f*x)))), x], x] /; FreeQ[{a, b, c, d, e, f}, x] && IntegerQ[2*k] && NeQ [a^2 - b^2, 0] && IGtQ[m, 0]
Int[((c_.) + (d_.)*(x_))^(m_.)/((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^2, x_ Symbol] :> Simp[b*(c + d*x)^m*(Cos[e + f*x]/(f*(a^2 - b^2)*(a + b*Sin[e + f *x]))), x] + (Simp[a/(a^2 - b^2) Int[(c + d*x)^m/(a + b*Sin[e + f*x]), x] , x] - Simp[b*d*(m/(f*(a^2 - b^2))) Int[(c + d*x)^(m - 1)*(Cos[e + f*x]/( a + b*Sin[e + f*x])), x], x]) /; FreeQ[{a, b, c, d, e, f}, x] && NeQ[a^2 - b^2, 0] && IGtQ[m, 0]
Int[(x_)^(m_.)*((a_) + (b_.)*Sin[(c_.) + (d_.)*(x_)]^2)^(n_), x_Symbol] :> Simp[1/2^n Int[x^m*(2*a + b - b*Cos[2*c + 2*d*x])^n, x], x] /; FreeQ[{a, b, c, d}, x] && NeQ[a + b, 0] && IGtQ[m, 0] && ILtQ[n, 0] && (EqQ[n, -1] || (EqQ[m, 1] && EqQ[n, -2]))
Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 2168 vs. \(2 (275 ) = 550\).
Time = 1.27 (sec) , antiderivative size = 2169, normalized size of antiderivative = 6.59
I/d^2/(a+b)*a/(a*(a+b))^(1/2)/(2*(a*(a+b))^(1/2)+2*a+b)*ln(1-b*exp(2*I*(d* x+c))/(2*(a*(a+b))^(1/2)+2*a+b))*c+I/d/(a+b)*a/(a*(a+b))^(1/2)/(2*(a*(a+b) )^(1/2)+2*a+b)*ln(1-b*exp(2*I*(d*x+c))/(2*(a*(a+b))^(1/2)+2*a+b))*x+I/d^2/ (a+b)/(a*(a+b))^(1/2)/(2*(a*(a+b))^(1/2)+2*a+b)*ln(1-b*exp(2*I*(d*x+c))/(2 *(a*(a+b))^(1/2)+2*a+b))*b*c+1/2/d/(a+b)/a*b^2/(a*(a+b))^(1/2)/(2*(a*(a+b) )^(1/2)+2*a+b)*c*x+I/d/(a+b)/(a*(a+b))^(1/2)/(2*(a*(a+b))^(1/2)+2*a+b)*ln( 1-b*exp(2*I*(d*x+c))/(2*(a*(a+b))^(1/2)+2*a+b))*b*x-1/2*I/d^2/(a+b)/a*b*c/ (a^2+a*b)^(1/2)*arctanh(1/4*(-2*b*exp(2*I*(d*x+c))+4*a+2*b)/(a^2+a*b)^(1/2 ))+1/2*I/d^2/(a+b)/a*b/(2*(a*(a+b))^(1/2)+2*a+b)*ln(1-b*exp(2*I*(d*x+c))/( 2*(a*(a+b))^(1/2)+2*a+b))*c-1/4*I/d^2/(a+b)/a*b/(a*(a+b))^(1/2)*ln(1-b*exp (2*I*(d*x+c))/(-2*(a*(a+b))^(1/2)+2*a+b))*c-1/4*I/d/(a+b)/a*b/(a*(a+b))^(1 /2)*ln(1-b*exp(2*I*(d*x+c))/(-2*(a*(a+b))^(1/2)+2*a+b))*x+1/2*I/d/(a+b)/a* b/(2*(a*(a+b))^(1/2)+2*a+b)*ln(1-b*exp(2*I*(d*x+c))/(2*(a*(a+b))^(1/2)+2*a +b))*x-I*x*(2*exp(2*I*(d*x+c))*a+b*exp(2*I*(d*x+c))-b)/a/(a+b)/d/(-b*exp(4 *I*(d*x+c))+4*exp(2*I*(d*x+c))*a+2*b*exp(2*I*(d*x+c))-b)+1/(a+b)/(a*(a+b)) ^(1/2)/(2*(a*(a+b))^(1/2)+2*a+b)*x^2*b+1/d^2/(a+b)/(2*(a*(a+b))^(1/2)+2*a+ b)*c^2+1/2/d^2/(a+b)/(2*(a*(a+b))^(1/2)+2*a+b)*polylog(2,b*exp(2*I*(d*x+c) )/(2*(a*(a+b))^(1/2)+2*a+b))-1/2/d^2/(a+b)/(a*(a+b))^(1/2)*c^2-1/4/d^2/(a+ b)/(a*(a+b))^(1/2)*polylog(2,b*exp(2*I*(d*x+c))/(-2*(a*(a+b))^(1/2)+2*a+b) )-1/4/d^2/(a+b)/a*ln(-b*exp(4*I*(d*x+c))+4*exp(2*I*(d*x+c))*a+2*b*exp(2...
Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 3960 vs. \(2 (280) = 560\).
Time = 1.94 (sec) , antiderivative size = 3960, normalized size of antiderivative = 12.04 \[ \int \frac {x}{\left (a+b \sin ^2(c+d x)\right )^2} \, dx=\text {Too large to display} \]
-1/8*(4*(a^2*b + a*b^2)*d*x*cos(d*x + c)*sin(d*x + c) + (2*a^2*b + 3*a*b^2 + b^3 - (2*a*b^2 + b^3)*cos(d*x + c)^2)*sqrt((a^2 + a*b)/b^2)*dilog((((2* a + b)*cos(d*x + c) + (2*I*a + I*b)*sin(d*x + c) - 2*(b*cos(d*x + c) + I*b *sin(d*x + c))*sqrt((a^2 + a*b)/b^2))*sqrt((2*b*sqrt((a^2 + a*b)/b^2) + 2* a + b)/b) - b)/b + 1) + (2*a^2*b + 3*a*b^2 + b^3 - (2*a*b^2 + b^3)*cos(d*x + c)^2)*sqrt((a^2 + a*b)/b^2)*dilog(-(((2*a + b)*cos(d*x + c) - (2*I*a + I*b)*sin(d*x + c) - 2*(b*cos(d*x + c) - I*b*sin(d*x + c))*sqrt((a^2 + a*b) /b^2))*sqrt((2*b*sqrt((a^2 + a*b)/b^2) + 2*a + b)/b) + b)/b + 1) + (2*a^2* b + 3*a*b^2 + b^3 - (2*a*b^2 + b^3)*cos(d*x + c)^2)*sqrt((a^2 + a*b)/b^2)* dilog((((2*a + b)*cos(d*x + c) + (-2*I*a - I*b)*sin(d*x + c) - 2*(b*cos(d* x + c) - I*b*sin(d*x + c))*sqrt((a^2 + a*b)/b^2))*sqrt((2*b*sqrt((a^2 + a* b)/b^2) + 2*a + b)/b) - b)/b + 1) + (2*a^2*b + 3*a*b^2 + b^3 - (2*a*b^2 + b^3)*cos(d*x + c)^2)*sqrt((a^2 + a*b)/b^2)*dilog(-(((2*a + b)*cos(d*x + c) - (-2*I*a - I*b)*sin(d*x + c) - 2*(b*cos(d*x + c) + I*b*sin(d*x + c))*sqr t((a^2 + a*b)/b^2))*sqrt((2*b*sqrt((a^2 + a*b)/b^2) + 2*a + b)/b) + b)/b + 1) - (2*a^2*b + 3*a*b^2 + b^3 - (2*a*b^2 + b^3)*cos(d*x + c)^2)*sqrt((a^2 + a*b)/b^2)*dilog((((2*a + b)*cos(d*x + c) + (2*I*a + I*b)*sin(d*x + c) + 2*(b*cos(d*x + c) + I*b*sin(d*x + c))*sqrt((a^2 + a*b)/b^2))*sqrt(-(2*b*s qrt((a^2 + a*b)/b^2) - 2*a - b)/b) - b)/b + 1) - (2*a^2*b + 3*a*b^2 + b^3 - (2*a*b^2 + b^3)*cos(d*x + c)^2)*sqrt((a^2 + a*b)/b^2)*dilog(-(((2*a +...
Timed out. \[ \int \frac {x}{\left (a+b \sin ^2(c+d x)\right )^2} \, dx=\text {Timed out} \]
Timed out. \[ \int \frac {x}{\left (a+b \sin ^2(c+d x)\right )^2} \, dx=\text {Timed out} \]
\[ \int \frac {x}{\left (a+b \sin ^2(c+d x)\right )^2} \, dx=\int { \frac {x}{{\left (b \sin \left (d x + c\right )^{2} + a\right )}^{2}} \,d x } \]
Timed out. \[ \int \frac {x}{\left (a+b \sin ^2(c+d x)\right )^2} \, dx=\int \frac {x}{{\left (b\,{\sin \left (c+d\,x\right )}^2+a\right )}^2} \,d x \]